<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jstl/core_rt" prefix="c" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
        "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <title>万达营销流程管理系统</title>
    <link href="../css/css.css" rel="stylesheet" type="text/css"/>
    <!--[if IE 6]>
    <script type="text/javascript" src="js/ie6png.js"></script>
    <script type="text/javascript">
        DD_belatedPNG.fix('div,ul,li,a,p,img,body,dl,dt,dd');</script>
    <![endif]-->
    <script type="text/javascript">
        function MM_jumpMenu(targ, selObj, restore) { //v3.0
            eval(targ + ".location='" + selObj.options[selObj.selectedIndex].value + "'");
            if (restore) selObj.selectedIndex = 0;
        }
        
        function daochuexcel(){
        	var head = "序号,项目,房间,建筑面积,套内面积,计价方式,建筑面积单价,套内面积单价,标准总价";
        	var roomIds = document.getElementsByName("roomId");
        	var projectNames = document.getElementsByName("projectName");
        	var roomCodes = document.getElementsByName("roomCode");
        	var buildUpAreas = document.getElementsByName("buildUpArea");
        	var innerAreas = document.getElementsByName("innerArea");
        	var payMethods = document.getElementsByName("payMethod");
			var unitPrices = document.getElementsByName("unitPrice");
			var innerPrices = document.getElementsByName("innerPrice");
			var sumPrices = document.getElementsByName("sumPrice");
			var c = "";
			var college = "";
			for(var i = 0;i < roomIds.length;i++){
				roomId = roomIds[i].value;
				projectName = projectNames[i].value;
				roomCode = roomCodes[i].value;
				buildUpArea = buildUpAreas[i].value;
				innerArea = innerAreas[i].value;
				payMethod = payMethods[i].value;
				unitPrice = unitPrices[i].value;
				innerPrice = innerPrices[i].value;
				sumPrice = sumPrices[i].value;
				c = roomId+","+projectName+","+roomCode+","+buildUpArea+","+innerArea+","+payMethod+","+unitPrice+","+innerPrice+","+sumPrice+";";
				college = college+c;
			}
			location.href = "daochubaobiao.do?college=" + college + "&header=" + head;
        }
        
        function todaoru(filename) {
		alert(filename);
			$.ajax({
				type:"POST",
				url:"openingreport/toDaoru.do",
				data:{
					"filename":filename
				},
				dataType:"json",
				success:function(data) {
					alert('导入成功!');
					setTimeout("location.reload()", 100);//页面刷新
				},
				error:function(data) {
					alert('vvv审核失败!');
				}
			});
			alert('aaa');
	}
    </script>
    <script>
        <!--
        /*第一种形式 第二种形式 更换显示样式*/
        function setTab(name, cursel, n) {
            for (i = 1; i <= n; i++) {
                var menu = document.getElementById(name + i);
                var con = document.getElementById("con_" + name + "_" + i);
                menu.className = i == cursel ? "hover" : "";
                con.style.display = i == cursel ? "block" : "none";
            }
        }

        //-->
    </script>
</head>
<body>
<div class="yboxwidth boxcenter ybox01">
    <div class="ybox09">
        <table width="100%" border="0" cellspacing="0" cellpadding="0">
            <tr>
                <td class="ybox10td1"><a href="#"><img src="../Images/op8_1.gif" width="28" height="54"/></a></td>
                <td>
                    <table border="0" cellspacing="0" cellpadding="0">
                        <tr valign="top">
                            <td class="ybox11td1"></td>
                            <td class="ybox11td2"><a href="toWriteBasicMess.do">1、填写基本信息</a></td>
                            <td class="ybox11td3"></td>
                            <td class="ybox11td2"><a href="toChooseHome.do">2、选择房间</a></td>
                            <td class="ybox11td8"></td>
                            <td class="ybox11td6"><a href="toImportPrice.do">3、导入价格</a></td>
                            <td class="ybox11td7"></td>
                            <td class="ybox11td2"><a href="toImportReducedRate.do">4、引入折扣方案</a></td>
                            <td class="ybox11td3"></td>
                            <td class="ybox11td2"><a href="toImportPayMethod.do">5、引入付款方式</a></td>
                            <td class="ybox11td3"></td>
                            <td class="ybox11td2"><a href="toChooseSaleReport.do">6、预览并提交</a></td>
                            <td class="ybox11td4"></td>
                        </tr>
                    </table>
                </td>
                <td class="ybox10td1"><a href="#"><img src="../Images/op8_2.gif" width="28" height="54"/></a></td>
            </tr>
        </table>
    </div>
    <div class="ybox02">
        <table width="100%" border="0" cellspacing="0" cellpadding="0" class="margb4">
            <tr>
                <td class="ybox03td1"></td>
                <td class="ybox03td2"></td>
                <td class="ybox03td3"></td>
            </tr>
            <tr>
                <td class="ybox03td4"></td>
                <td class="ybox03td5">
                    <div class="ybox05 margb8">
                        <dl>
                            <dt><strong>【注】</strong>1、点击"下载价格模板"，填写房间价格。<br/>
                                　　　2、点击"导入价格明细"，导入房间价格。
                            </dt>
                        </dl>
                    </div>
                    <div class="ybox07 margb2">
                        <dl>
                            <table border="0" cellspacing="0" cellpadding="0" class="ybox07table">
                                <tr align="left">
                                    <td class="ybox07td1"><img src="../Images/op4_4.gif"/></td>
                                    <td><a href="javascript:void(0);" onclick="daochuexcel()">下载价格模板</a></td>
                                    <td class="ybox07td2"><img src="../Images/op4_0.gif"/></td>
                                    <td class="ybox07td1"><img src="../Images/op4_5.gif"/></td>
                                    <td >
                                    	<a href="importPriceDialog.do">导入价格明细</a>
                                    </td>
                                    <td class="ybox07td2"><img src="../Images/op4_0.gif"/></td>
                                </tr>
                            </table>
                        </dl>
                    </div>
                    
                 <table width="100%" border="0" cellpadding="0" cellspacing="1" class="ybox06table">
                <tr>
                  <td class="ybox06td01">序号</td>
                  <td class="ybox06td01">项目</td>
                  <td class="ybox06td01">房间</td>
                  <td class="ybox06td01">建筑面积</td>
                  <td class="ybox06td01">套内面积</td>
                  <td class="ybox06td01">计价方式</td>
                  <td class="ybox06td01">建筑面积单价</td>
                  <td class="ybox06td01">套内面积单价</td>
                  <td class="ybox06td01">标准总价</td>
                </tr>
             <c:forEach var="wdhtroomModel" items="${listt}" varStatus="s">
                <tr>
                <input type="hidden" name="roomId" id="roomId" value="${wdhtroomModel.roomId }" style="border: none;"/>
                <td class="ybox06td02wcenter">${s.index+1}</td>
                
                <c:forEach  var="wdopeningreportModel" items="${list}"  >
                <%--  <td class="ybox06td02wleft" ><input type="text" name="projectName" value="${wdopeningreportModel.openingReportName}"/></td> --%>
               <td width="5">
	            <input type="text" name="projectName" value="${wdopeningreportModel.openingReportName}"  readonly="readonly"/>
	                            </td>
                </c:forEach>
                <%--  <td class="ybox06td02wleft" >${wdhtroomModel.roomCode}</td> --%>
                       <td width="5">
	       <input type="text" name="roomCode" value="${wdhtroomModel.roomCode }"  readonly="readonly"/>
	                            </td>         
                 <%-- <td class="ybox06td02wcenter" >${wdhtroomModel.buildUpArea}</td> --%>
                  <td width="5">
	            <input type="text" name="buildUpArea" value="${wdhtroomModel.buildUpArea }"  readonly="readonly"/>
	                            </td> 
                <%--  <td class="ybox06td02wcenter" >${wdhtroomModel.innerArea}</td> --%>
                  <td width="5">
	       <input type="text" name="innerArea" value="${wdhtroomModel.innerArea }" readonly="readonly"/>
	                            </td>
                 <!-- <td class="ybox06td02wcenter" >建筑面积</td> -->
            <td width="5">
	         <input type="text" name="payMethod" value="建筑面积" readonly="readonly"/>
	                            </td>      
                 <%-- <td class="ybox06td02wcenter" >${wdhtroomModel.innerPrice}</td> --%>
               <td width="5">
	          <input type="text" name="unitPrice" value="${wdhtroomModel.innerPrice }"  readonly="readonly"/>
	                            </td>  
               <%--   <td class="ybox06td02wcenter" >${wdhtroomModel.unitPrice}</td> --%>
                <td width="5">
	           <input type="text" name="innerPrice" value="${wdhtroomModel.unitPrice }"  readonly="readonly"/>
	                   </td>
               <%--   <td class="ybox06td02wcenter" >${wdhtroomModel.buildUpArea * wdhtroomModel.unitPrice}</td> --%>
               <td width="5">
	     <input type="text" name="sumPrice" value="${wdhtroomModel.buildUpArea * wdhtroomModel.unitPrice }" readonly="readonly"/>
	                            </td>
                </tr>
               
                </c:forEach>
                       <%-- <c:forEach items="${roomList1}" var="room">
                      		<tr>
	                            <td width="5">
	                            	<input type="text" name="roomId" value="${room.roomId}" style="border: none;" readonly="readonly"/>
	                            </td>
	                            <td width="5">
	                            	<input type="text" name="projectName" value="银川西夏万达广场" style="border: none;" readonly="readonly"/>
	                            </td>
	                            <td width="5">
	                            	<input type="text" name="roomCode" value="${room.roomCode }" style="border: none;" readonly="readonly"/>
	                            </td>
	                            <td width="5">
	                            	<input type="text" name="buildUpArea" value="${room.buildUpArea }" style="border: none;" readonly="readonly"/>
	                            </td>
	                            <td width="5">
	                            	<input type="text" name="innerArea" value="${room.innerArea }" style="border: none;" readonly="readonly"/>
	                            </td>
	                            <td width="5">
	                            	<input type="text" name="payMethod" value="建筑面积" style="border: none;" readonly="readonly"/>
	                            </td>
	                            <td width="5">
	                            	<input type="text" name="unitPrice" value="${room.unitPrice }" style="border: none;" readonly="readonly"/>
	                            </td>
	                            <td width="5">
	                            	<input type="text" name="innerPrice" value="${room.innerPrice }" style="border: none;" readonly="readonly"/>
	                            </td>
	                            <td width="5">
	                            	<input type="text" name="sumPrice" value="${room.buildUpArea * room.unitPrice }" style="border: none;" readonly="readonly"/>
	                            </td>
                        	</tr>
                      	</c:forEach> --%>
                      
                    </table>
                    <div class="nums boxcenter black12"><a href="#" class="hovera">首 页</a><a href="#">上一页</a><a
                            href="#">下一页</a><a href="#">尾 页</a>&nbsp;&nbsp;&nbsp;第1/3页&nbsp;&nbsp;&nbsp;每页&nbsp;
                        <input name="textfield3" type="text" id="textfield" size="2"/>
                        &nbsp;条/共25条&nbsp;&nbsp;转到&nbsp;
                        <input name="textfield3" type="text" id="textfield" size="2"/>
                        &nbsp;页<a href="#">跳 转</a></div>
                </td>
                <td class="ybox03td6"></td>
            </tr>
            <tr>
                <td class="ybox03td7"></td>
                <td class="ybox03td8"></td>
                <td class="ybox03td9"></td>
            </tr>
        </table>
        <table width="380" border="0" align="center" cellpadding="0" cellspacing="0">
            <tr>
                <td height="60" align="center"><a href="wuadd.do"><img src="../Images/botton01.gif" width="95" height="34"/></a>
                </td>
                <td align="center"><a href="fangan.do"><img src="../Images/botton02.gif" width="95" height="34"/></a></td>
            </tr>
        </table>
    </div>
</div>
</body>
</html>